package com.xyz.dao.logic;

import com.free.ext.mybatis.model.entity.PageResponseModel;
import com.xyz.dao.dao.CCustomeraccntlogDao;
import com.xyz.domain.table.CCustomeraccntlog;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Component;

import java.util.List;

@Component
public class CCustomeraccntlogLogic {

    @Autowired
    private CCustomeraccntlogDao cCustomeraccntlogDao;

    public CCustomeraccntlog add(CCustomeraccntlog cCustomeraccntlog){
        return cCustomeraccntlogDao.insert(cCustomeraccntlog);
    }

    public Integer update(CCustomeraccntlog cCustomeraccntlog){
        return cCustomeraccntlogDao.update(cCustomeraccntlog);
    }

    public List<CCustomeraccntlog> list(CCustomeraccntlog cCustomeraccntlog, String orderBy){
        return cCustomeraccntlogDao.selectList(cCustomeraccntlog, orderBy);
    }

    public Integer delete(Integer key){
        return cCustomeraccntlogDao.delete(key);
    }

    public PageResponseModel<CCustomeraccntlog> pageInfo(CCustomeraccntlog cCustomeraccntlog, String orderBy, Integer pageNo, Integer pageSize){
        return cCustomeraccntlogDao.selectByPageNo(cCustomeraccntlog, orderBy, pageNo, pageSize);
    }

}